M291 P"Select Option" R"Printer after print is finished" S4 K{"Sleep", "Stay idle"} F1

if input = 0
  M291 S4 K{"Ok", "Change"} P"After the print is finished, the printer will lower the bed to the selected height (default: all the way down)." R"Select Option"
  if input == 1
    M98 P"0:/macros/System/Settings/Job End/Bed Position"
  echo >"0:/sys/user/actions/PowerEndBehavior.g" "M98 P""0:/sys/user/actions/BedFinishBehavior.g"""
  echo >>"0:/sys/user/actions/PowerEndBehavior.g" "M400"
  echo >>"0:/sys/user/actions/PowerEndBehavior.g" "G4 S5"
  echo >>"0:/sys/user/actions/PowerEndBehavior.g" "M81 S1"
  echo "Sleep after print is finished selected"
elif input = 1
  echo >"0:/sys/user/actions/PowerEndBehavior.g" "; Stay idle after print is finished"
  echo "Stay idle after print is finished selected"